<?php
/**
 * created by zzy
 * date: 2017/10/24 9:40
 */
namespace App\Api\Service\Routes;

use Dingo\Api\Routing\Router;

class UserRoute
{
    public function map(Router $router)
    {
        $router->group(['namespace' => 'User\Controllers', 'prefix'=>'user'], function ($router) {

            $router->post('token', 'IndexController@token');
            $router->get('token', 'IndexController@token');

            $router->any('login', 'IndexController@login');
            $router->any('logout', 'IndexController@logout');
            $router->any('register', 'IndexController@register');
            $router->any('password', 'IndexController@setPassword');
            $router->any('sendSms', 'IndexController@sendSms');
            $router->any('checkCode', 'IndexController@checkCode');
            $router->any('company', 'IndexController@company');
            $router->any('message', 'MessageController@index');
            $router->any('messageList', 'MessageController@lists');
            $router->any('messageDel', 'MessageController@delete');
            $router->any('messageRead', 'MessageController@read');
            $router->any('messageMonth', 'MessageController@messageMonth');
            $router->any('messageNumber', 'MessageController@messageNumber');
            $router->any('message-change-one', 'MessageController@changeOne');

            $router->any('setPasswordByOldPassword', 'IndexController@setPasswordByOldPassword');


            $router->any('xxx', 'TestController@index');

        });
    }
}